package com.pinda.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.pinda.auth.entity.PdCoreStation;
import com.pinda.auth.view.StatusView;
import com.pinda.commonutils.Page;
import com.pinda.mapper.PdCoreStationMapper;
import com.pinda.service.IPdCoreStationService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 岗位 服务实现类
 * </p>
 *
 * @author 黄杰
 * @since 2023-06-13
 */
@Service
public class PdCoreStationServiceImpl extends ServiceImpl<PdCoreStationMapper, PdCoreStation> implements IPdCoreStationService {


    @Autowired
    private PdCoreStationMapper stationMapper;

    /**
     * 查询岗位
     * @param page
     * @return
     */
    @Override
    public PageInfo<StatusView> querystationService(Page<StatusView> page) {
        PageHelper.startPage(page.getPageNum(),page.getPageSize());
        return new PageInfo<>(this.stationMapper.querystatus(page.getSearch()));
    }
}
